﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Master.Master" AutoEventWireup="true" CodeBehind="HRDEvaluation.aspx.cs" Inherits="KPIS.GERP.GHRMS.APP.App_UI.Forms.HRDEvaluation" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <link href="../../Styles/CssClass.css" rel="stylesheet" type="text/css" />
    <link rel="StyleSheet" href="../../Styles/StyleSheet.css" type="text/css" />

    <style type="text/css">
        .textDisable {
            background-color: black;
        }
         .style2
         {
             width: 122px;
         }
        .style3
        {
            width: 416px;
        }
        .style5
        {
            width: 54px;
        }
        .style6
        {
            width: 395px;
        }
        .style7
        {
            width: 83px;
        }
        fieldset {
            border: solid 1px rgb(207, 221, 232);
            -moz-border-radius:3px;  
            border-radius: 3px;  
            -webkit-border-radius: 3px; 
             
        }
        legend {
            font-size: 13px;
            font-weight: bold;
        }
    </style>



</asp:Content>


<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
<% Response.Cache.AppendCacheExtension("no-cache"); %>

<script src="../../Resources/Scripts/jquery-1.9.0.min.js" type="text/javascript"></script>

<telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
    <script language="javascript" type="text/javascript">

        //document.body.onload = function () { window.history.forward(); }
    
        function preventBack() { window.history.forward(); }

        setTimeout("preventBack()", 0);

        window.onload = 'preventBack()';
        window.onpageshow = function (evt) { if (evt.persisted) preventBack() }

        window.onunload = function () { void (0) };  //{null};

        function Check() {
            if (!checkRadioInGridKPA()) return false;
            if (!checkRadioInGridStrategy()) return false;
            if (!checkRadioInGridCoreCompetency()) return false;
            if (!checkRadioInGridIDP()) return false;
            return confirm('คุณต้องการบันทึกข้อมูลใช่หรือไม่');
        }

        function OnScoreInGridCheck(grid) {            
            var MasterTable = grid.get_masterTableView();
            var length = MasterTable.get_dataItems().length;
            var count = 0;
            for (var i = 0; i < length; i++) {
                var rblScore = MasterTable.get_dataItems()[i].findElement("rblEmployeeScore"); //access the  control
                var elements = rblScore.getElementsByTagName("input");
                for (var j = 0; j < elements.length; j++) {
                    if (elements[j].checked) {
                        //alert(elements[j].value);
                        count++;
                    }
                }
            }
           
            if (count < length) {
                return false;

            }
            return true;
        
        } 

        function checkRadioInGridKPA() {
            var grid = $find("<%=grdRadKPA.ClientID %>");
            var ret = OnScoreInGridCheck(grid);
            if (!ret) {
                alert('กรุณาใส่คะแนน "งานตามภารกิจ" ให้ครบทุกช่อง');                
            }
            return ret;
        }  

        function checkRadioInGridStrategy() {
            var grid = $find("<%=grdRadStrategyProject.ClientID %>");
            var ret = OnScoreInGridCheck(grid);
            if (!ret) {
                alert('กรุณาใส่คะแนน "งานตามยุทธศาสตร์" ให้ครบทุกช่อง');
            }
            return ret;
        }

        function checkRadioInGridCoreCompetency() {
            var grid = $find("<%=grdRadCoreCompetency.ClientID %>");
            var ret = OnScoreInGridCheck(grid);
            if (!ret) {
                alert('กรุณาใส่คะแนน "สมรรถนะหลัก" ให้ครบทุกช่อง');
            }
            return ret;
        }

        function checkRadioInGridIDP() {
            var grid = $find("<%=grdRadIDP.ClientID %>");
            var ret = OnScoreInGridCheck(grid);
            if (!ret) {
                alert('กรุณาใส่คะแนน "สมรรถนะประจำตำแหน่งและสิ่งที่ต้องการพัฒนา" ให้ครบทุกช่อง');
            }
            return ret;
        }


        function onTabSelecting(sender, args) {

            var tabstrip = $find('<%= RadTabStrip1.ClientID %>');

            if (tabstrip.get_selectedTab().get_text() == "ผลการประเมิน") {

                document.getElementById("spanSave").style.display = "none";
                //document.getElementById("spanSaveResult").style.display = "";
            }
            else {
                document.getElementById("spanSave").style.display = "";
                //document.getElementById("spanSaveResult").style.display = "none";
            }
        }


    </script>
</telerik:RadCodeBlock>

<telerik:RadAjaxManager ID="RadManager1" runat="server" >
    <AjaxSettings>
        <telerik:AjaxSetting AjaxControlID="rblEmployeeScore">
            <UpdatedControls>
                <telerik:AjaxUpdatedControl ControlID="grdRadKPA" />
                <telerik:AjaxUpdatedControl ControlID="grdRadStrategyProject" />
                <telerik:AjaxUpdatedControl ControlID="grdRadCoreCompetency" />
                <telerik:AjaxUpdatedControl ControlID="grdRadIDP" />
            </UpdatedControls>
        </telerik:AjaxSetting>
    </AjaxSettings>
</telerik:RadAjaxManager>    

<br />
    <asp:HiddenField ID="HiddenField1" runat="server" />
<br />
<div class="PanelTopHeader" >    
    <asp:Label ID="lblHeader" runat="server" Text="ประเมินผลการปฏิบัติงาน" ForeColor="White" Font-Bold="true" Font-Size="Medium"></asp:Label>
</div>
<div class="Background980V3">
    <br />
    <table id="tblDetail"  width="970" cellpadding="0" cellspacing="0" >
        <tr>
            <td valign="top" class="style6">
                <table style="width: 385px">
                    <tr>
                        <td align="right" class="style2">ผู้รับการประเมิน :</td>
                        <td>
                            <asp:Label ID="lblName" runat="server" ></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="style2">ตำแหน่ง :</td>
                        <td>
                            <asp:Label ID="lblPosition" runat="server"></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="style2">ระดับ :</td>
                        <td>
                            <asp:Label ID="lblLevel" runat="server" ></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="style2">สังกัดหน่วยงาน :</td>
                        <td>
                            <asp:Label ID="lblJobSite" runat="server" ></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="style2">วันที่เข้าทำงาน :</td>
                        <td>
                            <asp:Label ID="lblDateAdmit" runat="server" >
                            </asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="style2">วันที่เริ่มรับตำแหน่ง :</td>
                        <td>
                            <asp:Label ID="lblDateWorkStart" runat="server" >
                            </asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="style2">รอบการประเมิน :</td>
                        <td>
                            <asp:Label ID="lblRound" runat="server" ></asp:Label>
                        </td>
                    </tr>
                </table>
            </td>

            <td valign = "top" class="style3" >
            <br />
           <%-- <div style="width: 550px; margin-bottom: 5px; ">--%>
                
                 <asp:Panel id="pnlAbsent" runat="server"  Width="550px">
                     <table width="100%">
                        <tr align="center">
                            <td class="style5"></td>
                            <td>ลาป่วย</td>
                            <td class="style7">ลากิจ</td>
                            <td>ลาพักผ่อน</td>
                            <td>มาสาย</td>
                            <td>ลาอื่นๆ</td>
                            <td>รวมวัน</td>
                        </tr>
                        <tr align="center" >
                            <td class="style5">โควต้า :</td>
                            <td><asp:Label ID="lblLimitSick" runat="server"></asp:Label></td>
                            <td><asp:Label ID="lblLimitLeave" runat="server"></asp:Label></td>
                            <td><asp:Label ID="lblLimitHoliday" runat="server"></asp:Label></td>
                            <td><asp:Label ID="lblLimitLate" runat="server"></asp:Label></td>
                            <td><asp:Label ID="lblLimitOther" runat="server"></asp:Label></td>
                            <td><asp:Label ID="lblLimitSum" runat="server"></asp:Label></td>
                        </tr>
                        <tr align="center">
                            <td align="right" class="style5">หยุดจริง :</td>
                            <td><asp:Label ID="lblSick" runat="server"></asp:Label></td>
                            <td><asp:Label ID="lblLeave" runat="server"></asp:Label></td>
                            <td><asp:Label ID="lblHoliday" runat="server"></asp:Label></td>
                            <td><asp:Label ID="lblLate" runat="server"></asp:Label></td>
                            <td><asp:Label ID="lblOther" runat="server"></asp:Label></td>
                            <td><asp:Label ID="lblSum" runat="server"></asp:Label></td>
                        </tr>
                     </table>

                 </asp:Panel>
            <%--</div>--%>
            </td>
            
        </tr>

    </table>
    <br />
    <br />
</div>
<div class="PanelTopHeader" >

    <table id="tblTopHeader" width="100%">
        <tr>
            <td>
                <span id="spanSave">
                <asp:LinkButton ID="btnSave" runat="server" CssClass="LinkButtonWhite" OnClick="btnSave_Clicked"
                    OnClientClick="return Check(); " >
                    <img alt="" style="border:0px;vertical-align:middle;" src="../Images/Buttons/saveDisk.gif" />&nbsp;บันทึกข้อมูล
                </asp:LinkButton>
                </span>
            </td>
        </tr>
    </table>
</div>

        <%--<telerik:RadTabStrip ID="RadTabStrip1"  runat="server" OnClientTabSelected="onTabSelecting" ScrollChildren="True"
            SelectedIndex="0" MultiPageID="RadMultiPage1" ScrollButtonsPosition="Right" PerTabScrolling="True" ScrollPosition="0">
             
            <Tabs>
                <telerik:RadTab Text="งานตามยุทธศาสตร์" Selected="true" ToolTip="Strategy" >
                </telerik:RadTab>
                <telerik:RadTab Text="งานตามภารกิจ" ToolTip="KPA"  >
                </telerik:RadTab>
                <telerik:RadTab Text="สมรรรถนะหลัก" ToolTip="Core Competency" >
                </telerik:RadTab>
                <telerik:RadTab Text="งานเพื่อกระตุ้นการพัฒนา" ToolTip="Performance Agreement" >
                </telerik:RadTab>
                <telerik:RadTab Text="สมรรถนะประจำตำแหน่งและสิ่งที่ต้องการพัฒนา" ToolTip="IDP" >
                </telerik:RadTab>
                <telerik:RadTab Text="ผลการประเมิน" ToolTip="Result" >
                </telerik:RadTab>
                <telerik:RadTab Text="แผนพัฒนารายบุคคล" ToolTip="Individual Development Planning" >
                </telerik:RadTab>
            </Tabs>
        </telerik:RadTabStrip>--%>
    
    
        <telerik:RadTabStrip ID="RadTabStrip1" runat="server" Width="970px" OnClientTabSelected="onTabSelecting" ScrollChildren="True"
            SelectedIndex="0" MultiPageID="RadMultiPage1" PerTabScrolling="True">
            <Tabs>
                <telerik:RadTab Text="งานตามยุทธศาสตร์" ToolTip="Strategy" Selected="True">
                </telerik:RadTab>
                <telerik:RadTab Text="งานตามภารกิจ" ToolTip="KPA" >
                </telerik:RadTab>
                <telerik:RadTab Text="สมรรรถนะหลัก" ToolTip="Core Competency" >
                </telerik:RadTab> 
                <telerik:RadTab Text="งานเพื่อกระตุ้นการพัฒนา" ToolTip="Performance Agreement">
                </telerik:RadTab>
                <telerik:RadTab Text="สมรรถนะประจำตำแหน่งและสิ่งที่ต้องการพัฒนา" ToolTip="IDP"  >
                </telerik:RadTab>
                <telerik:RadTab Text="ผลการประเมิน" ToolTip="Result" >
                </telerik:RadTab>
                <telerik:RadTab Text="แผนพัฒนารายบุคคล" ToolTip="Individual Development Planning" >
                </telerik:RadTab>
            </Tabs>
        </telerik:RadTabStrip>

        <telerik:RadMultiPage ID="RadMultiPage1" runat="server" SelectedIndex="0" Height="600px" Width="100%" 
            BorderStyle="Outset" BorderColor="Silver" BorderWidth="1px">
            <!-- //Tab1 -->

            <telerik:RadPageView ID="pgvRadStrategy" runat="server">
                <span style="color:white">Strategy</span><br/>
                <telerik:RadGrid ID="grdRadStrategyProject" runat="server" ShowFooter="True"
                        AutoGenerateColumns="False" BorderColor="Gray" BorderWidth="1px" Width="100%" 
                        OnItemDataBound="grdRadStrategyProject_ItemDataBound" >
                    <MasterTableView Width="100%" ShowHeadersWhenNoRecords="true" TableLayout="Fixed" 
                        DataKeyNames="bgm_proj_job_assign_seq">
                    <NoRecordsTemplate>
                        <div> There are no records to display </div>
                    </NoRecordsTemplate>

                    <ColumnGroups>
                        <telerik:GridColumnGroup HeaderText="ประเมินตนเอง"
                            Name="Employee" HeaderStyle-Font-Bold="true" 
                            HeaderStyle-HorizontalAlign="Center" >
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                        </telerik:GridColumnGroup>

                        <telerik:GridColumnGroup HeaderText="หัวหน้าประเมิน"
                            Name="Supervisor" HeaderStyle-Font-Bold="true" 
                            HeaderStyle-HorizontalAlign="Center" >
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                        </telerik:GridColumnGroup>
                    </ColumnGroups>

                    <Columns>
                    <telerik:GridBoundColumn DataField="full_score" Visible="false" >
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="isdetailweight" Visible="false" >
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="weight" Visible="false" >
                            </telerik:GridBoundColumn>

                        <telerik:GridTemplateColumn HeaderText="ลำดับ"  ItemStyle-HorizontalAlign="Center" >
                            <ItemTemplate>
                                <%# Container.DataSetIndex+1 %>
                            </ItemTemplate>
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="50px" />
                        </telerik:GridTemplateColumn>

                        <telerik:GridBoundColumn HeaderText="งานตามยุทธศาสตร์" DataField="bgm_proj_name" >
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                        </telerik:GridBoundColumn>

                        <telerik:GridBoundColumn HeaderText="รายละเอียดงาน" DataField="job_title" >
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                        </telerik:GridBoundColumn>

                        <telerik:GridBoundColumn HeaderText="description" DataField="job_description" Visible="false" >
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                        </telerik:GridBoundColumn>

                        <telerik:GridTemplateColumn AutoPostBackOnFilter="true" UniqueName="EmployeeScore"
                            ColumnGroupName="Employee" HeaderText="คะแนน" >
                            <ItemStyle HorizontalAlign="Left" />
                            <FooterStyle HorizontalAlign="Right" />
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                            <HeaderTemplate>
                            <asp:HyperLink ID="LinkEmpScore" runat="server" Text="คะแนน" Target="_blank"
                                NavigateUrl="HRDScoringPerformance.aspx" ToolTip="คลิกที่นี่เพื่อดูคำอธิบาย" Font-Underline="True">
                                   </asp:HyperLink>
                                     &nbsp;<img alt="คลิกที่ลิงค์เพื่อดูคำอธิบาย" src="../Images/General/question_blue.png"/ title="คลิกที่ลิงค์เพื่อดูคำอธิบาย">
                            </HeaderTemplate>
                            <FooterTemplate>
                                <asp:Label ID="lblFooterStrategyTotalScore" runat="server" style=" text-align:right;" Font-Bold="True"></asp:Label>
                            </FooterTemplate>
                            <ItemTemplate> 
                               <asp:RadioButtonList ID="rblEmployeeScore" RepeatDirection="Horizontal" AutoPostBack="false"  
                                    runat="server" GroupName="rblEmployeeScoreGroup" RepeatLayout="Flow"
                                    DataTextField="score_text" DataValueField="score_value">
                                </asp:RadioButtonList>
                                <asp:HiddenField ID="hdnFullScore" runat="server" />
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>

                        <telerik:GridTemplateColumn AutoPostBackOnFilter="true"
                            ColumnGroupName="Employee" HeaderText="เหตุผล" >
                            <ItemTemplate> 
                                <telerik:RadTextBox ID="txtEmployeeComment" runat="server" 
                                    TextMode="MultiLine" Width="145px" Height="50px" AutoPostBack="false">
                                </telerik:RadTextBox>
                            </ItemTemplate>
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                        </telerik:GridTemplateColumn>

                        <telerik:GridTemplateColumn AutoPostBackOnFilter="true" UniqueName="SupervisorScore"
                            ColumnGroupName="Supervisor" HeaderText="คะแนน" >
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                            <HeaderTemplate>
                                <asp:HyperLink ID="LinkSupScore" runat="server" Text="คะแนน" Target="_blank" 
                                    NavigateUrl="HRDScoringPerformance.aspx" ToolTip="คลิกที่นี่เพื่อดูคำอธิบาย" Font-Underline="True">
                                </asp:HyperLink>
                                &nbsp;<img alt="คลิกที่ลิงค์เพื่อดูคำอธิบาย" src="../Images/General/question_blue.png"/ title="คลิกที่ลิงค์เพื่อดูคำอธิบาย">
                            </HeaderTemplate>
                            <FooterStyle HorizontalAlign="Right" />
                            <FooterTemplate>
                                    <asp:Label ID="lblFooterStrategySupTotalScore" runat="server" Font-Bold="True"></asp:Label>
                            </FooterTemplate>
                            <ItemTemplate> 
                               <asp:RadioButtonList ID="rblSupervisorScore" RepeatDirection="Horizontal" AutoPostBack="false"
                                    runat="server" GroupName="rblSupervisorScore" RepeatLayout="Flow" Enabled="false"
                                    DataTextField="score_text" DataValueField="score_value">
                                </asp:RadioButtonList>
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>

                        <telerik:GridTemplateColumn AutoPostBackOnFilter="true"
                            ColumnGroupName="Supervisor" HeaderText="เหตุผล">
                            <ItemTemplate> 
                                <telerik:RadTextBox ID="txtSupervisorComment" runat="server" AutoPostBack="false"
                                    TextMode="MultiLine" Width="145px" Height="50px"  Enabled="false">
                                </telerik:RadTextBox>
                            </ItemTemplate>
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                        </telerik:GridTemplateColumn>
                    </Columns>
                    </MasterTableView>
                </telerik:RadGrid>

                <br />
                <br />
                <asp:Panel ID="Panel1" runat="server" GroupingText="หมายเหตุ" >
                    <telerik:RadTextBox ID="txtRadRemarkStrategy" runat="server" TextMode="MultiLine" 
                        Height="100px" Width="100%" > 
                    </telerik:RadTextBox>
                </asp:Panel>
                <br />
                <br />
                <br />
            </telerik:RadPageView>

           <!-- Tab2 -->
            <telerik:RadPageView ID="pgvRadKPA" runat="server">
                <span style="color:white">KPA</span><br/>
                <telerik:RadGrid ID="grdRadKPA" runat="server" CellSpacing="0" GridLines="None" ShowFooter="True"
                        AutoGenerateColumns="false" BorderColor="Gray" BorderWidth="1px" Width="100%" 
                        OnItemDataBound="grdRadKPA_ItemDataBound">
                    <MasterTableView Width="100%" ShowHeadersWhenNoRecords="true" TableLayout="Fixed" 
                        DataKeyNames="kpa_seq">
                    <NoRecordsTemplate>
                        <div> There are no records to display </div>
                    </NoRecordsTemplate>

                    <ColumnGroups>
                        <telerik:GridColumnGroup HeaderText="ประเมินตนเอง"
                            Name="Employee" HeaderStyle-Font-Bold="true" 
                            HeaderStyle-HorizontalAlign="Center" >
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                        </telerik:GridColumnGroup>

                        <telerik:GridColumnGroup HeaderText="หัวหน้าประเมิน"
                            Name="Supervisor" HeaderStyle-Font-Bold="true" 
                            HeaderStyle-HorizontalAlign="Center" >
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                        </telerik:GridColumnGroup>
                    </ColumnGroups>

                        <CommandItemSettings ExportToPdfText="Export to PDF" />
                        <RowIndicatorColumn FilterControlAltText="Filter RowIndicator column" 
                            Visible="True">
                        </RowIndicatorColumn>
                        <ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column" 
                            Visible="True">
                        </ExpandCollapseColumn>
                        <Columns>
                            <telerik:GridBoundColumn DataField="full_score" Visible="false" >
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="isdetailweight" Visible="false" >
                            </telerik:GridBoundColumn>
                            <telerik:GridTemplateColumn HeaderText="ลำดับ"  ItemStyle-HorizontalAlign="Center" >
                                <ItemTemplate>
                                    <%# Container.DataSetIndex+1 %>
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="50px" />
                                <ItemStyle HorizontalAlign="Center" />
                            </telerik:GridTemplateColumn>
                            <telerik:GridBoundColumn DataField="key_area_name" 
                                HeaderText="เขตความรับผิดชอบ">
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="description" HeaderText="รายละเอียดงาน">
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                            </telerik:GridBoundColumn>
                            <telerik:GridNumericColumn Aggregate="Sum" DataField="weight" 
                                FooterStyle-Font-Bold="true" FooterAggregateFormatString="รวม: {0:N0}" 
                                HeaderText="น้ำหนัก(%)" ItemStyle-HorizontalAlign="Right">
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="100px" />
                                <FooterStyle HorizontalAlign="Right" />
                                <ItemStyle HorizontalAlign="Right" />
                            </telerik:GridNumericColumn>
                            <telerik:GridTemplateColumn AutoPostBackOnFilter="true" 
                                ColumnGroupName="Employee" HeaderText="คะแนน" UniqueName="employee_score" DataField="employee_score">
                                <ItemStyle HorizontalAlign="Left" />
                                <FooterStyle HorizontalAlign="Right" />
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                                <HeaderTemplate>
                               <asp:HyperLink ID="LinkEmpScore" runat="server" Text="คะแนน" Target="_blank"
                                    NavigateUrl="HRDScoringPerformance.aspx" ToolTip="คลิกที่นี่เพื่อดูคำอธิบาย" Font-Underline="True">
                                   </asp:HyperLink>
                                     &nbsp;<img alt="คลิกที่ลิงค์เพื่อดูคำอธิบาย" src="../Images/General/question_blue.png"/ title="คลิกที่ลิงค์เพื่อดูคำอธิบาย">
                                </HeaderTemplate>
                                <FooterTemplate>
                                    <asp:Label ID="lblFooterTotalScore" runat="server" style=" text-align:right;" Font-Bold="True"></asp:Label>
                                </FooterTemplate>
                                <ItemTemplate>
                                    <asp:RadioButtonList ID="rblEmployeeScore" runat="server" AutoPostBack="true"  
                                        DataTextField="score_text" DataValueField="score_value" 
                                        GroupName="rblEmployeeScoreGroup" RepeatDirection="Horizontal" 
                                        RepeatLayout="Flow">
                                    </asp:RadioButtonList>
                                    <asp:HiddenField ID="hdnFullScore" runat="server" />
                                </ItemTemplate>
                            </telerik:GridTemplateColumn>
                            <telerik:GridTemplateColumn AutoPostBackOnFilter="true" 
                                ColumnGroupName="Employee" HeaderText="เหตุผล">
                                <ItemTemplate>
                                    <telerik:RadTextBox ID="txtEmployeeComment" runat="server" Height="50px" AutoPostBack="true" 
                                        TextMode="MultiLine" Width="145px">
                                    </telerik:RadTextBox>
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                            </telerik:GridTemplateColumn>
                            <telerik:GridTemplateColumn AutoPostBackOnFilter="true" 
                                ColumnGroupName="Supervisor" HeaderText="คะแนน" UniqueName="SupervisorScore">
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                                <HeaderTemplate>
                                    <asp:HyperLink ID="LinkSupScore" runat="server" Text="คะแนน" Target="_blank" 
                                        NavigateUrl="HRDScoringPerformance.aspx" ToolTip="คลิกที่นี่เพื่อดูคำอธิบาย" Font-Underline="True">
                                    </asp:HyperLink>
                                         &nbsp;<img alt="คลิกที่ลิงค์เพื่อดูคำอธิบาย" src="../Images/General/question_blue.png"/ title="คลิกที่ลิงค์เพื่อดูคำอธิบาย">
                                </HeaderTemplate>
                                <FooterStyle HorizontalAlign="Right" />
                                <FooterTemplate>
                                    <asp:Label ID="lblFooterKPASupTotalScore" runat="server" Font-Bold="True"></asp:Label>
                                </FooterTemplate>
                                <ItemTemplate>
                                    <asp:RadioButtonList ID="rblSupervisorScore" runat="server" AutoPostBack="true" 
                                        DataTextField="score_text" DataValueField="score_value" Enabled="false"
                                        GroupName="rblSupervisorScore" RepeatDirection="Horizontal" RepeatLayout="Flow">
                                    </asp:RadioButtonList>
                                </ItemTemplate>
                            </telerik:GridTemplateColumn>
                            <telerik:GridTemplateColumn AutoPostBackOnFilter="true" 
                                ColumnGroupName="Supervisor" HeaderText="เหตุผล">
                                <ItemTemplate>
                                    <telerik:RadTextBox ID="txtSupervisorComment" runat="server" Height="50px" 
                                        TextMode="MultiLine" Width="145px" Enabled="false" AutoPostBack="true">
                                    </telerik:RadTextBox>
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                            </telerik:GridTemplateColumn>
                        </Columns>
                        <EditFormSettings>
                            <EditColumn FilterControlAltText="Filter EditCommandColumn column">
                            </EditColumn>
                        </EditFormSettings>
                    </MasterTableView>
                    <FilterMenu EnableImageSprites="False">
                    </FilterMenu>
                </telerik:RadGrid>

                <br />
                <br />
                <asp:Panel ID="pnlRemark" runat="server" GroupingText="หมายเหตุ" >
                    <telerik:RadTextBox ID="txtRadRemarkKPA" runat="server" TextMode="MultiLine" 
                        Height="100px" Width="100%" >
                    </telerik:RadTextBox>
                </asp:Panel>
                <br />
                <br />
                <br />
            </telerik:RadPageView>

            <!-- Tab3 -->
            <telerik:RadPageView ID="pgvRadCoreCompetency" runat="server">
                <span style="color:white">Core Competency</span><br/>
                <telerik:RadGrid ID="grdRadCoreCompetency" runat="server" CellSpacing="0" GridLines="None" ShowFooter="True"
                        AutoGenerateColumns="false" BorderColor="Gray" BorderWidth="1px" Width="100%" 
                        OnItemDataBound="grdRadCoreCompetency_ItemDataBound" >
                    <MasterTableView Width="100%" ShowHeadersWhenNoRecords="true" TableLayout="Fixed" 
                        DataKeyNames="pos_competency_seq">
                    <NoRecordsTemplate>
                        <div> There are no records to display </div>
                    </NoRecordsTemplate>

                    <ColumnGroups>
                        <telerik:GridColumnGroup HeaderText="ประเมินตนเอง"
                            Name="Employee" HeaderStyle-Font-Bold="true" 
                            HeaderStyle-HorizontalAlign="Center" >
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                        </telerik:GridColumnGroup>

                        <telerik:GridColumnGroup HeaderText="หัวหน้าประเมิน"
                            Name="Supervisor" HeaderStyle-Font-Bold="true" 
                            HeaderStyle-HorizontalAlign="Center" >
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                        </telerik:GridColumnGroup>
                    </ColumnGroups>

                        <CommandItemSettings ExportToPdfText="Export to PDF" />
                        <RowIndicatorColumn FilterControlAltText="Filter RowIndicator column" 
                            Visible="True">
                        </RowIndicatorColumn>
                        <ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column" 
                            Visible="True">
                        </ExpandCollapseColumn>
                        <Columns>
                        <telerik:GridBoundColumn DataField="full_score" Visible="false" >
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="isdetailweight" Visible="false" >
                            </telerik:GridBoundColumn>

                            <telerik:GridTemplateColumn HeaderText="ลำดับ"  ItemStyle-HorizontalAlign="Center">
                                <ItemTemplate>
                                    <%# Container.DataSetIndex+1 %>
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="50px" />
                            </telerik:GridTemplateColumn>
                            <telerik:GridBoundColumn DataField="core_competency_name" 
                                HeaderText="สมรรถนะหลัก">
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="level_name" HeaderText="ระดับสมรรถนะ">
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="description" HeaderText="description" 
                                Visible="false">
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                            </telerik:GridBoundColumn>
                            <telerik:GridNumericColumn Aggregate="Sum" DataField="weight" 
                                FooterStyle-Font-Bold="true" FooterAggregateFormatString="รวม: {0:N0}"
                                HeaderText="น้ำหนัก(%)" ItemStyle-HorizontalAlign="Right">
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="100px" />
                                <FooterStyle HorizontalAlign="Right" />
                                <ItemStyle HorizontalAlign="Right" />
                            </telerik:GridNumericColumn>
                            <telerik:GridTemplateColumn AutoPostBackOnFilter="true" 
                                ColumnGroupName="Employee" HeaderText="คะแนน" UniqueName="EmployeeScore">
                                <ItemStyle HorizontalAlign="Left" />
                                <FooterStyle HorizontalAlign="Right" />
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                                <HeaderTemplate>
                                <asp:HyperLink ID="LinkEmpScore" runat="server" Text="คะแนน" Target="_blank"
                                    NavigateUrl="HRDScoringPerformance.aspx" ToolTip="คลิกที่นี่เพื่อดูคำอธิบาย" Font-Underline="True">
                                   </asp:HyperLink>
                                     &nbsp;<img alt="คลิกที่ลิงค์เพื่อดูคำอธิบาย" src="../Images/General/question_blue.png"/ title="คลิกที่ลิงค์เพื่อดูคำอธิบาย">
                                </HeaderTemplate>
                                <FooterTemplate>
                                    <asp:Label ID="lblFooterCoreCompetencyTotalScore" runat="server" Font-Bold="True"></asp:Label>
                                </FooterTemplate>
                                <ItemTemplate>
                                    <asp:RadioButtonList ID="rblEmployeeScore" runat="server" AutoPostBack="false"
                                        DataTextField="score_text" DataValueField="score_value" 
                                        GroupName="rblEmployeeScoreGroup" RepeatDirection="Horizontal" 
                                        RepeatLayout="Flow" >
                                    </asp:RadioButtonList>
                                    <asp:HiddenField ID="hdnFullScore" runat="server" />
                                </ItemTemplate>
                            </telerik:GridTemplateColumn>
                            <telerik:GridTemplateColumn AutoPostBackOnFilter="true" 
                                ColumnGroupName="Employee" HeaderText="เหตุผล">
                                <ItemTemplate>
                                    <telerik:RadTextBox ID="txtEmployeeComment" runat="server" Height="50px" 
                                        TextMode="MultiLine" Width="145px" AutoPostBack="false">
                                    </telerik:RadTextBox>
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                            </telerik:GridTemplateColumn>
                            <telerik:GridTemplateColumn AutoPostBackOnFilter="true" 
                                ColumnGroupName="Supervisor" HeaderText="คะแนน" UniqueName="SupervisorScore">
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                                <HeaderTemplate>
                                <asp:HyperLink ID="LinkSupScore" runat="server" Text="คะแนน" Target="_blank"
                                    NavigateUrl="HRDScoringPerformance.aspx" ToolTip="คลิกที่นี่เพื่อดูคำอธิบาย" Font-Underline="True">
                                   </asp:HyperLink>
                                     &nbsp;<img alt="คลิกที่ลิงค์เพื่อดูคำอธิบาย" src="../Images/General/question_blue.png"/ title="คลิกที่ลิงค์เพื่อดูคำอธิบาย">
                                </HeaderTemplate>
                                <FooterStyle HorizontalAlign="Right" />
                                <FooterTemplate>
                                    <asp:Label ID="lblFooterCoreCompetencySupTotalScore" runat="server" Font-Bold="True"></asp:Label>
                                </FooterTemplate>
                                <ItemTemplate>
                                    <asp:RadioButtonList ID="rblSupervisorScore" runat="server"  AutoPostBack="false"
                                        DataTextField="score_text" DataValueField="score_value" Enabled="false"
                                        GroupName="rblSupervisorScore" RepeatDirection="Horizontal" RepeatLayout="Flow">
                                    </asp:RadioButtonList>
                                </ItemTemplate>
                            </telerik:GridTemplateColumn>
                            <telerik:GridTemplateColumn AutoPostBackOnFilter="true" 
                                ColumnGroupName="Supervisor" HeaderText="เหตุผล">
                                <ItemTemplate>
                                    <telerik:RadTextBox ID="txtSupervisorComment" runat="server" Height="50px" 
                                        TextMode="MultiLine" Width="145px" Enabled="false" AutoPostBack="false" >
                                    </telerik:RadTextBox>
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                            </telerik:GridTemplateColumn>
                        </Columns>
                        <EditFormSettings>
                            <EditColumn FilterControlAltText="Filter EditCommandColumn column">
                            </EditColumn>
                        </EditFormSettings>
                    </MasterTableView>
                    <FilterMenu EnableImageSprites="False">
                    </FilterMenu>
                </telerik:RadGrid>

                <br />
                <br />
                <asp:Panel ID="Panel2" runat="server" GroupingText="หมายเหตุ" >
                    <telerik:RadTextBox ID="txtRadRemarkCoreCompetency" runat="server" TextMode="MultiLine" 
                        Height="100px" Width="100%" >
                    </telerik:RadTextBox>
                </asp:Panel>
                <br />
                <br />
                <br />
            </telerik:RadPageView>

            <!-- Tab4 -->
            <telerik:RadPageView ID="pgvRadPerformanceAgreement" runat="server">
                <span style="color:white">Performance Agreement</span><br />
                <br />
                <asp:Panel ID="pnlGoalObj" runat="server" GroupingText="งานที่ต้องการพัฒนา">
                    <telerik:RadTextBox ID="txtGoalObjective" runat="server" TextMode="MultiLine" 
                        Height="100px" Width="100%" >
                    </telerik:RadTextBox>
                </asp:Panel>
                <br />
                <br />

                <asp:Panel ID="pnlDevelopmentNeed" runat="server" GroupingText="งานมอบหมายพิเศษเพื่อการพัฒนา" >
                <br />
                    <telerik:RadGrid ID="grdRadDevelopmentNeed" runat="server" CellSpacing="0" GridLines="None"
                        AutoGenerateColumns="false" BorderColor="Gray" BorderWidth="1px" Width="100%" >
                    <MasterTableView Width="100%" ShowHeadersWhenNoRecords="true" TableLayout="Fixed" 
                        DataKeyNames="emp_seq">
                    <NoRecordsTemplate>
                        <div> There are no records to display </div>
                    </NoRecordsTemplate>
                        <Columns>
                            <telerik:GridBoundColumn HeaderStyle-Font-Bold="true" HeaderText="ประเภทสมรรถนะ"
                                    DataField="type_name" >
                                    <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                                </telerik:GridBoundColumn>
                                
                                <telerik:GridBoundColumn HeaderStyle-Font-Bold="true" HeaderText="ความชำนาญ"
                                    DataField="proficiency_name">
                                    <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                                </telerik:GridBoundColumn>
                        </Columns>
                    </MasterTableView>
                </telerik:RadGrid>
                <br />
                </asp:Panel>

                <br />
                <br />
                <asp:Panel ID="pnlActionPlan" runat="server" GroupingText="กิจกรรมพิเศษเพื่อส่วนรวม" >
                    <table width="100%">
                        <tr>
                            <td>
                                
                            </td>
                            <td title="ประเมินคะแนนตนเอง" width="100px">
                                ประเมินตนเอง: 
                            </td>
                            <td rowspan="2" style="border-left: solid 1px grey;">
                                
                            </td>
                            <td title="ประเมินคะแนนโดยผู้บังคับบัญชา" width="100px">
                                หัวหน้าประเมิน: 
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <telerik:RadTextBox ID="txtRadActionPlan" runat="server" TextMode="MultiLine"  
                                    Height="100px" Width="100%" >
                                </telerik:RadTextBox>
                            </td>
                            <td>
                                
                                <asp:RadioButtonList ID="rblActionPlanScore" runat="server" RepeatDirection="Horizontal" Enabled="True">
                                    <asp:ListItem>1</asp:ListItem>
                                    <asp:ListItem>2</asp:ListItem>
                                    <asp:ListItem Selected="True">3</asp:ListItem>
                                    <asp:ListItem>4</asp:ListItem>
                                    <asp:ListItem>5</asp:ListItem>
                                </asp:RadioButtonList>
                            </td>
                            <td>
                                
                                <asp:RadioButtonList ID="rblActionPlanScoreSupervisor" runat="server" RepeatDirection="Horizontal" 
                                    Enabled="False">
                                    <asp:ListItem>1</asp:ListItem>
                                    <asp:ListItem>2</asp:ListItem>
                                    <asp:ListItem>3</asp:ListItem>
                                    <asp:ListItem>4</asp:ListItem>
                                    <asp:ListItem>5</asp:ListItem>
                                </asp:RadioButtonList>
                            </td>
                        </tr>
                    </table> 
                </asp:Panel>
                <br />
                <br />
                <br />
            </telerik:RadPageView>

            <!-- Tab5 -->
            <telerik:RadPageView ID="pgvRadIDP" runat="server">
                <span style="color:white">IDP</span>
                <telerik:RadGrid ID="grdRadIDP" runat="server" CellSpacing="0" GridLines="None" ShowFooter="True"
                        AutoGenerateColumns="false" BorderColor="Gray" BorderWidth="1px" Width="100%" 
                        OnItemDataBound="grdRadIDP_ItemDataBound">
                    <MasterTableView Width="100%" ShowHeadersWhenNoRecords="true" TableLayout="Fixed" 
                        DataKeyNames="idp_seq">
                    <NoRecordsTemplate>
                        <div> There are no records to display </div>
                    </NoRecordsTemplate>

                    <ColumnGroups>
                        <telerik:GridColumnGroup HeaderText="ประเมินตนเอง"
                            Name="Employee" HeaderStyle-Font-Bold="true" 
                            HeaderStyle-HorizontalAlign="Center" >
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                        </telerik:GridColumnGroup>

                        <telerik:GridColumnGroup HeaderText="หัวหน้าประเมิน"
                            Name="Supervisor" HeaderStyle-Font-Bold="true" 
                            HeaderStyle-HorizontalAlign="Center" >
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                        </telerik:GridColumnGroup>
                    </ColumnGroups>

                        <CommandItemSettings ExportToPdfText="Export to PDF" />
                        <RowIndicatorColumn FilterControlAltText="Filter RowIndicator column" 
                            Visible="True">
                        </RowIndicatorColumn>
                        <ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column" 
                            Visible="True">
                        </ExpandCollapseColumn>
                        <Columns>

                        <telerik:GridBoundColumn DataField="full_score" Visible="false" >
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="isdetailweight" Visible="false" >
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="weight" Visible="false" >
                            </telerik:GridBoundColumn>

                            <telerik:GridTemplateColumn HeaderText="ลำดับ"  ItemStyle-HorizontalAlign="Center">
                                <ItemTemplate>
                                    <%# Container.DataSetIndex+1 %>
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="50px" />
                            </telerik:GridTemplateColumn>
                            <telerik:GridBoundColumn DataField="type_name" HeaderText="ประเภทสมรรถนะ">
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="proficiency_name" HeaderText="ความชำนาญ">
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                            </telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="description" HeaderText="description" 
                                Visible="false">
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                            </telerik:GridBoundColumn>
                            <telerik:GridTemplateColumn AutoPostBackOnFilter="true" 
                                ColumnGroupName="Employee" HeaderText="คะแนน" UniqueName="EmployeeScore">
                                <ItemStyle HorizontalAlign="Left" />
                                <FooterStyle HorizontalAlign="Right" />
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                                <HeaderTemplate>
                                <asp:HyperLink ID="LinkEmpScore" runat="server" Text="คะแนน" Target="_blank"
                                    NavigateUrl="HRDScoringPerformance.aspx" ToolTip="คลิกที่นี่เพื่อดูคำอธิบาย" Font-Underline="True">
                                   </asp:HyperLink>
                                     &nbsp;<img alt="คลิกที่ลิงค์เพื่อดูคำอธิบาย" src="../Images/General/question_blue.png"/ title="คลิกที่ลิงค์เพื่อดูคำอธิบาย">
                                </HeaderTemplate>
                                <ItemTemplate>
                                    <asp:RadioButtonList ID="rblEmployeeScore" runat="server" AutoPostBack="false"
                                        DataTextField="score_text" DataValueField="score_value" 
                                        GroupName="rblEmployeeScoreGroup" RepeatDirection="Horizontal" 
                                        RepeatLayout="Flow">
                                    </asp:RadioButtonList>
                                    <asp:HiddenField ID="hdnFullScore" runat="server" />
                                </ItemTemplate>
                            </telerik:GridTemplateColumn>
                            <telerik:GridTemplateColumn AutoPostBackOnFilter="true" 
                                ColumnGroupName="Employee" HeaderText="เหตุผล">
                                <ItemTemplate>
                                    <telerik:RadTextBox ID="txtEmployeeComment" runat="server" Height="50px" 
                                        TextMode="MultiLine" Width="145px" AutoPostBack="false">
                                    </telerik:RadTextBox>
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                            </telerik:GridTemplateColumn>
                            <telerik:GridTemplateColumn AutoPostBackOnFilter="true" 
                                ColumnGroupName="Supervisor" HeaderText="คะแนน" UniqueName="SupervisorScore">
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                                <HeaderTemplate>
                                <asp:HyperLink ID="LinkSupScore" runat="server" Text="คะแนน" Target="_blank"
                                    NavigateUrl="HRDScoringPerformance.aspx" ToolTip="คลิกที่นี่เพื่อดูคำอธิบาย" Font-Underline="True">
                                   </asp:HyperLink>
                                     &nbsp;<img alt="คลิกที่ลิงค์เพื่อดูคำอธิบาย" src="../Images/General/question_blue.png"/ title="คลิกที่ลิงค์เพื่อดูคำอธิบาย">
                                </HeaderTemplate>
                                <ItemTemplate>
                                    <asp:RadioButtonList ID="rblSupervisorScore" runat="server" AutoPostBack="false"
                                        DataTextField="score_text" DataValueField="score_value" Enabled="false"
                                        GroupName="rblSupervisorScore" RepeatDirection="Horizontal" RepeatLayout="Flow">
                                    </asp:RadioButtonList>
                                </ItemTemplate>
                            </telerik:GridTemplateColumn>
                            <telerik:GridTemplateColumn AutoPostBackOnFilter="true" 
                                ColumnGroupName="Supervisor" HeaderText="เหตุผล" >
                                <ItemTemplate>
                                    <telerik:RadTextBox ID="txtSupervisorComment" runat="server" Height="50px" 
                                        TextMode="MultiLine" Width="145px" Enabled="false" AutoPostBack="false">
                                    </telerik:RadTextBox>
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="160px" />
                            </telerik:GridTemplateColumn>
                        </Columns>
                        <EditFormSettings>
                            <EditColumn FilterControlAltText="Filter EditCommandColumn column">
                            </EditColumn>
                        </EditFormSettings>
                    </MasterTableView>
                    <FilterMenu EnableImageSprites="False">
                    </FilterMenu>
                </telerik:RadGrid>

                <br />
                <br />
                <asp:Panel ID="Panel3" runat="server" GroupingText="หมายเหตุ" >
                    <telerik:RadTextBox ID="txtRadRemarkIDP" runat="server" TextMode="MultiLine" 
                        Height="100px" Width="100%" >
                    </telerik:RadTextBox>
                </asp:Panel>
                <br />
                <br />
                <br />
            </telerik:RadPageView>

            <telerik:RadPageView ID="pgvRadResult" runat="server" >
                <span style="color:white">Result</span>
                 <div class="Background980V2" style="width: 98%;" >
                    <asp:Repeater ID="rpt" runat="server" OnItemDataBound="rpt_ItemDataBound">
                        <ItemTemplate>     
	                            <asp:Label ID="Label1"
                            runat="server" Text='<%# string.Format("{0} ({1} %)", Eval("header_name"), Eval("weight")) %>' Font-Bold="True" Font-Size="Medium"></asp:Label>
                        
                                <telerik:RadGrid ID="grdRadResult" runat="server" CellSpacing="0" GridLines="None" ShowFooter="True"
                                    AutoGenerateColumns="false" BorderColor="Gray" BorderWidth="1px" Width="100%" >
                                    <MasterTableView Width="100%" ShowHeadersWhenNoRecords="true" TableLayout="Fixed" >
                                        <NoRecordsTemplate>
                                            <div> There are no records to display </div>
                                        </NoRecordsTemplate>

                                        <ColumnGroups>
                                            <telerik:GridColumnGroup HeaderText="คะแนน"
                                                Name="Result" HeaderStyle-Font-Bold="true" 
                                                HeaderStyle-HorizontalAlign="Center" >
                                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                                            </telerik:GridColumnGroup>

                                            <telerik:GridColumnGroup HeaderText="คะแนนตามน้ำหนัก"
                                                Name="ResultByWeight" HeaderStyle-Font-Bold="true" 
                                                HeaderStyle-HorizontalAlign="Center" >
                                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                                            </telerik:GridColumnGroup>
                                        </ColumnGroups>

                                        <CommandItemSettings ExportToPdfText="Export to PDF" />

                                        <RowIndicatorColumn FilterControlAltText="Filter RowIndicator column" 
                                            Visible="True">
                                        </RowIndicatorColumn>

                                        <ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column" 
                                            Visible="True">
                                        </ExpandCollapseColumn>

                                        <Columns>

                                            <telerik:GridBoundColumn HeaderText="ประเภทการประเมิน" DataField="list_name" >
                                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="200px" />
                                            </telerik:GridBoundColumn>

                                            <telerik:GridNumericColumn Aggregate="Sum" DataField="weight" 
                                                FooterStyle-Font-Bold="true" FooterAggregateFormatString="รวม: {0:N0}" 
                                                HeaderText="น้ำหนัก(%)" ItemStyle-HorizontalAlign="Right">
                                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="100px" />
                                                <FooterStyle HorizontalAlign="Right" />
                                                <ItemStyle HorizontalAlign="Right" />
                                            </telerik:GridNumericColumn>

                                            <telerik:GridNumericColumn Aggregate="Sum" DataField="employee_total_score" DataFormatString="{0:N0}"
                                                FooterStyle-Font-Bold="true" FooterAggregateFormatString="{0:N0}" 
                                                HeaderText="ประเมินตนเอง" ItemStyle-HorizontalAlign="Right" ColumnGroupName="Result">
                                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="100px" />
                                                <FooterStyle HorizontalAlign="Right" />
                                                <ItemStyle HorizontalAlign="Right" />
                                            </telerik:GridNumericColumn>

                                            <telerik:GridNumericColumn Aggregate="Sum" DataField="supervisor_total_score" DataFormatString="{0:N0}" 
                                                FooterStyle-Font-Bold="true" FooterAggregateFormatString="{0:N0}" 
                                                HeaderText="หัวหน้าประเมิน" ItemStyle-HorizontalAlign="Right" ColumnGroupName="Result">
                                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="100px" />
                                                <FooterStyle HorizontalAlign="Right" />
                                                <ItemStyle HorizontalAlign="Right" />
                                            </telerik:GridNumericColumn>

                                            <telerik:GridNumericColumn Aggregate="Sum" DataField="empby_weight" DataFormatString="{0:N0}"
                                                FooterStyle-Font-Bold="true" FooterAggregateFormatString="{0:N0}" 
                                                HeaderText="ประเมินตนเอง" ItemStyle-HorizontalAlign="Right" ColumnGroupName="ResultByWeight">
                                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="100px" />
                                                <FooterStyle HorizontalAlign="Right" />
                                                <ItemStyle HorizontalAlign="Right" />
                                            </telerik:GridNumericColumn>

                                            <telerik:GridNumericColumn Aggregate="Sum" DataField="supby_weight" DataFormatString="{0:N0}"
                                                FooterStyle-Font-Bold="true" FooterAggregateFormatString="{0:N0}"  
                                                HeaderText="หัวหน้าประเมิน" ItemStyle-HorizontalAlign="Right" ColumnGroupName="ResultByWeight">
                                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="100px" />
                                                <FooterStyle HorizontalAlign="Right" />
                                                <ItemStyle HorizontalAlign="Right" />
                                            </telerik:GridNumericColumn>

                                        </Columns>
                                    </MasterTableView>
                            </telerik:RadGrid> 
                            <br />
                        </ItemTemplate>    
                    </asp:Repeater>
                    <br />
                </div>
            
            </telerik:RadPageView>
            
            <telerik:RadPageView ID="pgvRadIndividualDevelopmentPlanning" runat="server" >
                <span style="color:white">IndividualDevelopmentPlanning</span>
                
                <!-- Tab6 -->
                <telerik:RadGrid ID="grdRadResultIDP" runat="server" CellSpacing="0" ShowFooter="True"
                    GridLines="None" AutoGenerateColumns="false" BorderColor="Gray" BorderWidth="1px" 
                    Width="100%"  OnItemDataBound="grdRadResultIDP_ItemDataBound" >
                    <MasterTableView Width="100%" ShowHeadersWhenNoRecords="true" TableLayout="Fixed" 
                        DataKeyNames="evaluation_detail_seq" >
                    <NoRecordsTemplate>
                        <div> There are no records to display </div>
                    </NoRecordsTemplate>

                    <ColumnGroups>
                        <telerik:GridColumnGroup HeaderText="หัวหน้าประเมิน"
                            Name="Supervisor" HeaderStyle-Font-Bold="true" 
                            HeaderStyle-HorizontalAlign="Center" >
                            <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                        </telerik:GridColumnGroup>
                    </ColumnGroups>

                        <CommandItemSettings ExportToPdfText="Export to PDF" />
                        <RowIndicatorColumn FilterControlAltText="Filter RowIndicator column" 
                            Visible="True">
                        </RowIndicatorColumn>
                        <ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column" 
                            Visible="True">
                        </ExpandCollapseColumn>

                        <Columns>

                            <telerik:GridTemplateColumn HeaderText="ลำดับ" ItemStyle-HorizontalAlign="Center">
                                <ItemTemplate>
                                    <%# Container.DataSetIndex+1 %>
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="50px" />
                            </telerik:GridTemplateColumn>

                            <telerik:GridBoundColumn HeaderText="ประเภทสมรรถนะ" DataField ="detail_description"  >
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                            </telerik:GridBoundColumn>

                            <telerik:GridBoundColumn HeaderText="สมรรถนะ" DataField ="long_description" >
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" />
                            </telerik:GridBoundColumn>

                            <telerik:GridBoundColumn HeaderText="ค่าความต่าง" DataField ="gap_result"
                                ItemStyle-HorizontalAlign="Center">
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="80px" />
                            </telerik:GridBoundColumn>

                            <telerik:GridTemplateColumn  HeaderText="วิธีการพัฒนา" ColumnGroupName="Supervisor"
                                ItemStyle-HorizontalAlign="Center">
                                <ItemTemplate>
                                    <telerik:RadComboBox ID="cboRadDevMethod" runat="server" Width="190px" 
                                        DataTextField="method_name" DataValueField="dev_method_seq" Enabled="false">
                                    </telerik:RadComboBox>
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="200px" />
                            </telerik:GridTemplateColumn>

                            <telerik:GridTemplateColumn  HeaderText="ความสำคัญ" ColumnGroupName="Supervisor"
                                ItemStyle-HorizontalAlign="Center">
                                <ItemTemplate>
                                    <asp:RadioButtonList ID="rblPriority" runat="server" RepeatDirection="Horizontal"
                                        AutoPostBack="false" RepeatLayout="Flow" Enabled="false">
                                        <asp:ListItem Value="1">1</asp:ListItem>
                                        <asp:ListItem Value="2">2</asp:ListItem>
                                        <asp:ListItem Value="3">3</asp:ListItem>
                                    </asp:RadioButtonList>
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center"/>
                            </telerik:GridTemplateColumn>

                            <telerik:GridTemplateColumn  HeaderText="ไตรมาส" ColumnGroupName="Supervisor"
                                ItemStyle-HorizontalAlign="Center">
                                <ItemTemplate>
                                    <asp:RadioButtonList ID="rblQuarter" runat="server" RepeatDirection="Horizontal"
                                        AutoPostBack="false" RepeatLayout="Flow" Enabled="false">
                                        <asp:ListItem Value="1">1</asp:ListItem>
                                        <asp:ListItem Value="2">2</asp:ListItem>
                                        <asp:ListItem Value="3">3</asp:ListItem>
                                        <asp:ListItem Value="4">4</asp:ListItem>
                                    </asp:RadioButtonList>
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center"/>
                            </telerik:GridTemplateColumn>

                            <telerik:GridTemplateColumn  HeaderText="เหตุผล" ColumnGroupName="Supervisor" >
                                <ItemTemplate>
                                    <telerik:RadTextBox ID="txtReason" runat="server" Height="50px"  
                                        TextMode="MultiLine" Width="130px" AutoPostBack="false" Enabled="false">
                                    </telerik:RadTextBox>
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" HorizontalAlign="Center" Width="150px" />
                            </telerik:GridTemplateColumn>

                        </Columns>
                    </MasterTableView>
                </telerik:RadGrid>

            </telerik:RadPageView>

        </telerik:RadMultiPage>



</asp:Content>
